<?php

namespace App\Http\Controllers\Miniprograme;

use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use EasyWeChat\Factory;
class ComController extends Controller
{
    protected $miniProgram,$manager;
    public function __construct()
    {
        $config = [
            'app_id' => config('wechat.mini_program.default.app_id'),
            'secret' => config('wechat.mini_program.default.secret'),
        ];
        $this->miniProgram = Factory::miniProgram($config); // 小程序
        $config = [
            'app_id' => config('wechat.mini_program.manager.app_id'),
            'secret' => config('wechat.mini_program.manager.secret'),
        ];
        $this->manager = Factory::miniProgram($config); // 小程序

    }
}
